package com.workplan.client.widgets.currentemployees;

import net.customware.gwt.presenter.client.widget.WidgetDisplay;

import com.general.client.basewidget.BaseWidget;
import com.general.client.widgets.styledlist.StyledList;
import com.google.gwt.core.client.GWT;
import com.google.gwt.uibinder.client.UiBinder;
import com.google.gwt.uibinder.client.UiField;
import com.google.gwt.user.client.ui.Label;
import com.google.gwt.user.client.ui.Widget;

public class CurrentEmployees extends BaseWidget implements
		CurrentEmployeesPresenter.Display {

	@UiField
	Label label;

	@UiField
	StyledList list;

	@UiField(provided = true)
	Widget historyModal;

	@UiField(provided = true)
	Widget yesNoModal;

	private static CurrentEmployeesUiBinder uiBinder = GWT
			.create(CurrentEmployeesUiBinder.class);

	interface CurrentEmployeesUiBinder extends
			UiBinder<Widget, CurrentEmployees> {
	}

	public CurrentEmployees() {

	}

	@Override
	public void init() {
		initWidget(uiBinder.createAndBindUi(this));
		label.setText("Current Employees");
	}

	@Override
	public void addListItem(WidgetDisplay display) {
		list.add(display.asWidget());
	}

	@Override
	public void setHistoryModal(WidgetDisplay display) {
		historyModal = display.asWidget();
	}

	@Override
	public void setYesNoModal(WidgetDisplay display) {
		yesNoModal = display.asWidget();
	}

}
